package com.proyecto.personas.modelo.dto;


public class IdiomaId implements java.io.Serializable {

	// Fields

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	private String ciaopr;

	private String idiomacod;

	public IdiomaId() {
	}

	public IdiomaId(String ciaopr, String idiomacod) {
		this.ciaopr = ciaopr;
		this.idiomacod = idiomacod;
	}


	public String getCiaopr() {
		return this.ciaopr;
	}

	public void setCiaopr(String ciaopr) {
		this.ciaopr = ciaopr;
	}

	public String getIdiomacod() {
		return this.idiomacod;
	}

	public void setIdiomacod(String idiomacod) {
		this.idiomacod = idiomacod;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof IdiomaId))
			return false;
		IdiomaId castOther = (IdiomaId) other;

		return ((this.getCiaopr() == castOther.getCiaopr()) || (this
				.getCiaopr() != null
				&& castOther.getCiaopr() != null && this.getCiaopr().equals(
				castOther.getCiaopr())))
				&& ((this.getIdiomacod() == castOther.getIdiomacod()) || (this
						.getIdiomacod() != null
						&& castOther.getIdiomacod() != null && this
						.getIdiomacod().equals(castOther.getIdiomacod())));
	}

	public int hashCode() {
		int result = 17;

		result = 37 * result
				+ (getCiaopr() == null ? 0 : this.getCiaopr().hashCode());
		result = 37 * result
				+ (getIdiomacod() == null ? 0 : this.getIdiomacod().hashCode());
		return result;
	}

}